package com.diandian.backend.dingding.data.param;

import com.diandian.base.boot.starter.exception.DefaultException;

import java.io.Serializable;

public class DingdingStaffSalaryStaffPageOpenApiParam implements Serializable {

	private Integer pageNum;
	private Integer pageSize;

	private String queryUserJobNumber; // 查询人的工号，用来做权限过滤，生成deptPathPrefix，不用来直接做查询过滤
	private String belong;

	public void check(){
		if(this.pageNum == null || this.pageNum < 1 || this.pageSize == null || this.pageSize < 1){
			throw new DefaultException("分页参数不合法");
		}
		if(this.belong == null || this.belong.equals("")){
			throw new DefaultException("归属标识不能为空");
		}
		if(this.queryUserJobNumber == null || this.queryUserJobNumber.equals("")){
			throw new DefaultException("工号不能为空");
		}
	}

	public Integer getPageNum() {
		return pageNum;
	}

	public void setPageNum(Integer pageNum) {
		this.pageNum = pageNum;
	}

	public Integer getPageSize() {
		return pageSize;
	}

	public void setPageSize(Integer pageSize) {
		this.pageSize = pageSize;
	}

	public String getQueryUserJobNumber() {
		return queryUserJobNumber;
	}

	public void setQueryUserJobNumber(String queryUserJobNumber) {
		this.queryUserJobNumber = queryUserJobNumber;
	}

	public String getBelong() {
		return belong;
	}

	public void setBelong(String belong) {
		this.belong = belong;
	}
}
